package com.homework.dto;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Max;
import javax.validation.constraints.Min;
import java.time.LocalTime;

@Data
public class ClassScheduleDTO {

    private Long id;

    @NotNull(message = "学生ID不能为空")
    private Long studentId;

    @NotNull(message = "星期几不能为空")
    @Min(value = 1, message = "星期几必须在1-5之间")
    @Max(value = 5, message = "星期几必须在1-5之间")
    private Integer dayOfWeek;

    @NotNull(message = "节次不能为空")
    @Min(value = 1, message = "节次必须在1-8之间")
    @Max(value = 8, message = "节次必须在1-8之间")
    private Integer sessionOrder;

    @NotBlank(message = "科目名称不能为空")
    private String subject;

    private String teacherName;

    private String classroom;

    @NotNull(message = "开始时间不能为空")
    private LocalTime startTime;

    @NotNull(message = "结束时间不能为空")
    private LocalTime endTime;

    private Boolean isActive = true;
}